import request from '@/utils/request'


// 查询出货单列表
export function getDeliveryOrder(query) {
  return request({
    url: '/basic/warehouse/deliveryOrder/',
    method: 'get',
    params: query
  })
}


// 查询出货单详情
export function getDeliveryOrderDetail(query) {
  return request({
    url: '/basic/warehouse/deliveryOrder/'+query,
    method: 'get'
  })
}



// 删除出货单
export function delDeliveryOrder(query) {
  return request({
    url: '/basic/warehouse/deliveryOrder/'+query,
    method: 'delete'
  })
}


// 新增出货单
export function addDeliveryOrder(query) {
  return request({
    url: '/basic/warehouse/deliveryOrder/',
    method: 'post',
    params: query
  })
}


// 修改出货单
export function updateDeliveryOrder(query) {
  return request({
    url: '/basic/warehouse/deliveryOrder/',
    method: 'put',
    data: query
  })
}


// 确认出货单
export function deliveryOrderConfirm(query) {
  return request({
    url: '/basic/warehouse/deliveryOrder/confirm',
    method: 'put',
    params:query
  })
}

//出货单明细列表
export function particularsList(query) {
  return request({
    url: '/basic/warehouse/deliveryOrder/particulars',
    method: 'get',
    params: query
  })
}
//出货单明细详情
export function particularDetail(id) {
  return request({
    url: '/basic/warehouse/deliveryOrderDetail/particulars/'+ id,
    method: 'get'
  })
}
//出货单明细汇总
export function particularSum(query) {
  return request({
    url: '/basic/warehouse/deliveryOrderDetail/all/particulars',
    method: 'get',
    params: query
  })
}


